package com.nbicc.survey.service;

import com.nbicc.common.RequestPageObj;
import com.nbicc.common.ResponseObj;
import com.nbicc.survey.po.Answer;
import com.nbicc.survey.po.QuestionnaireTopicEntire;

import java.io.Serializable;
import java.util.List;
import java.util.Map;

/**
 * @Author: lilingyan
 * @Date 2018/12/6 11:23
 */
public interface IAnswerService {

    Answer selectById(String id);

    Integer insert(Answer answer) ;

    Integer batchInsert(List<Answer> answerList)throws Exception ;

    Integer updateById(Answer answer);

    Integer deleteById(String id);

    Integer countAnswererByQuestionnaireIdAndTopicId(String questionnaireId, String topicId);

    List<Map<String, Serializable>> resultAggregator(String questionnaireId, String topicId);

    ResponseObj find(RequestPageObj<Map<String, Object>> requestPageObj);

    QuestionnaireTopicEntire statisticsQuestionnaire(String questionnaireId);
}
